<template>
	<view class="item-box" @click="toDetails">
		<view class="cus-detail">
			<view class="user-img">
			</view>
			<view class="user-msg">
				<view class="cus-name">
					<view>{{$utils.eliminate(item.custName)}}</view>
					<view style="margin-left: 24upx;color: #666666;">{{$utils.eliminate(item.customerGender,'无')}}</view>
				</view>			
				<view class="carNO">{{$utils.eliminate(item.carLicense)}}</view>
			</view>
			<view class="user-type">
				<view>
					[{{$utils.eliminate(item.custType)}}]
				</view>
				<view @click.stop="makeCall(item.tel)">
					<u-icon name="phone"></u-icon>
					{{$utils.eliminate(item.tel)}}
				</view>
			</view>
		</view>
		<view class="cus-car">
			<view class="car-name">
				车系:{{$utils.eliminate(item.carSeries)}}
			</view>
			<view class="car-vin">
				VIN:{{$utils.eliminate(item.vin)}}
			</view>
		</view>
	</view>
</template>

<script>
	export default{
		props:{
			item:{type:Object,default:()=>{}},
			orderId:{type:String,default:()=>{}}
		},
		data(){
			return {
				
			}
		},
		methods:{
			toDetails(){
				uni.navigateTo({
				    url: `/pages/views/cusList/details?vin=${this.item.vin}&custNo=${this.item.custNo}&isOtherCar=${this.item.isOtherCar}&custType=${this.item.custType}`
				});				
			},
			makeCall(tel){
				uni.makePhoneCall({
				    phoneNumber: tel
				});				
			}
		}
	}
</script>

<style lang="scss" scoped>
  @import './cusItem.scss';
</style>
